<template>
	<view>
		<view class="upper">
			<view :style="{height: (navigationBarHeight + statusBarHeight) + 'px'}"></view>

			<view class="list">
				<view class="one two">
					<view class="big">
						<view class="son"></view>
					</view>
					<view class="txt">
						一分钟获取选校方案
					</view>
				</view>
				<view class="one">
					<view class="big">
						<view class="son"></view>
					</view>
					<view class="txt">
						AI智能选校
					</view>
				</view>
			</view>

			<view class="list-two">
				<view class="txt">
					收录9000+院校
				</view>
				<view class="txt">
					基于科学的拟合算法
				</view>
				<view class="txt">
					征集多方专家方案
				</view>
			</view>
			<!-- <view class="title">
				<image class="title_AI" src="https://img.wilmer.com.cn/admin/2024/3-22/WechatIMG23.jpg" mode="">
				</image>
				<image class="title_nav" src="https://img.wilmer.com.cn/admin/2024/3-22/WechatIMG22.jpg" mode="">
				</image>
			</view>
			<view class="title_text" style="margin-top: 40rpx;">
				<view class="icon"></view>
				<text>一分钟获取选校方案</text>
			</view>
			<view class="title_text">
				<view class="icon"></view>
				<text>AI智能选校</text>
			</view> -->
			<view class="btn conter" @click="startTest()">开始测试</view>
		</view>
		<!-- <view class="below">
			<view class="explain">收录1000+院校</view>
			<view class="explain">基于科学的拟合算法</view>
			<view class="explain">征集多方专家方案</view>
			<view class="btn conter" @click="startTest()">开始测试</view>
		</view> -->
	</view>
</template>

<script>
	import {
		UserTokenKey
	} from '../../static/libs/config.js'
	import {
		Getprofile
	} from '@/common/api/homePage.js'
	export default {
		data() {
			return {
				token: "",
				statusBarHeight: 0, // 状态栏高度
				navigationBarHeight: 44, // 导航栏高度
			}
		},
		onShow() {
			this.token = uni.getStorageSync(UserTokenKey)
			// 获取状态栏高度
			const systemInfo = uni.getSystemInfoSync();
			this.statusBarHeight = systemInfo.statusBarHeight || 0;
		},
		methods: {
			async startTest() {
				let res = await Getprofile()
				if (this.token == '' || this.token == undefined || this.token == null) {
					setTimeout(() => {
						uni.navigateTo({
							url: '/pages/Login/Login-shortcut'
						})
					}, 1000)
					return
				}
				uni.navigateTo({
					url: '/pages/customer/Choose'
				})
			}
		}
	}
</script>

<style lang="scss" scoped>
	.upper {
		background: url('https://img.wilmer.com.cn/admin/2024/Group%20344%20%281%29.png') no-repeat;
		background-size: 100% 100%;
		width: 100vw;
		// height: 360px;
		height: 100vh;

		.btn {
			width: 686rpx;
			height: 100rpx;
			border-radius: 50rpx;
			font-family: Branding-BoldItalic;
			font-size: 24px;
			font-weight: 500;
			letter-spacing: 0.03em;
			color: #fff;
			background: #006270;
			position: absolute;
			bottom: 80rpx;
			left: 50%;
			transform: translate(-50%, 0);
		}

		.list {
			position: absolute;
			top: 560rpx;
			left: 44rpx;

			.one {
				display: flex;

				.big {
					width: 24rpx;
					height: 24rpx;
					border-radius: 50%;
					background-color: #02616F;
					position: relative;
					margin-top: 10rpx;
					margin-right: 18rpx;

					.son {
						width: 12rpx;
						height: 12rpx;
						background-color: #02616F;
						border-radius: 50%;
						background-color: #fff;
						position: absolute;
						top: 50%;
						left: 50%;
						transform: translate(-50%, -50%);
					}
				}

				.txt {
					font-size: 32rpx;
					font-weight: 500;
					color: #02616F;
				}
			}

			.two {
				margin-bottom: 15rpx;
			}
		}

		.list-two {
			position: absolute;
			top: 880rpx;
			left: 40rpx;

			.txt {
				color: #02616F;
				margin-bottom: 30rpx;
			}
		}

		// .title {
		// 	margin-top: 20rpx;
		// 	margin-left: 32rpx;
		// 	display: flex;
		// 	align-items: flex-end;

		// 	.title_AI {
		// 		width: 196rpx;
		// 		height: 144rpx;
		// 	}

		// 	.title_nav {
		// 		width: 414rpx;
		// 		height: 106rpx;
		// 		margin-left: 48rpx;
		// 	}
		// }

		// .title_text {
		// 	display: flex;
		// 	align-items: center;
		// 	margin-left: 44rpx;
		// 	margin-top: 20rpx;

		// 	.icon {
		// 		width: 24rpx;
		// 		height: 24rpx;
		// 		background-color: #fff;
		// 		border-radius: 50%;
		// 		border: 6rpx solid #007AFF;
		// 		box-sizing: border-box;
		// 		margin-right: 14rpx;
		// 	}

		// 	text {
		// 		font-family: Branding-BoldItalic;
		// 		font-size: 48rpx;
		// 		font-weight: 500;
		// 		color: #007AFF;
		// 	}
		// }
	}

	// .below {
	// 	background: url('https://img.wilmer.com.cn/admin/2024/3-13/WechatIMG265.jpg') no-repeat;
	// 	background-size: 100% 100%;
	// 	width: 100vw;
	// 	height: calc(100vh - 360px - 32rpx);
	// 	padding-top: 32rpx;
	// 	position: relative;

	// 	.explain {
	// 		font-family: Branding-BoldItalic;
	// 		font-size: 16px;
	// 		font-weight: 400;
	// 		letter-spacing: 0.03em;
	// 		margin-left: 40rpx;
	// 		margin-top: 24rpx;
	// 	}

	// 	.btn {
	// 		width: 686rpx;
	// 		height: 100rpx;
	// 		border-radius: 50rpx;
	// 		font-family: Branding-BoldItalic;
	// 		font-size: 24px;
	// 		font-weight: 500;
	// 		letter-spacing: 0.03em;
	// 		color: #fff;
	// 		background: #006270;
	// 		position: absolute;
	// 		bottom: 80rpx;
	// 		left: 50%;
	// 		transform: translate(-50%, 0);
	// 	}
	// }
</style>